<?php

namespace app\admin\controller;

use think\Db;
use think\Request;


class Centent extends Admin
{


    // 查询数据
    public function index()
    {

        // 查询用户
        $list = Db::table('hmy_user')
            ->field('id,name')
            ->select();


        return view('admin@centent/centent',['list'=>$list]);
    }


    // 查询数据
    public function find($id)
    {
        $list = Db::table('picture')
            ->where('user_id ='.$id)
            ->select();


        return view('admin@centent/detail',['list'=>$list]);
    }

    public function role($id)
    {

         Db::table('goods')->where('id ='.$id) ->delete();

        return view('admin@centent/index');






    }

}


